package day03.practice;
import java.util.Scanner;

/**
 * @author yangwenqi
 * @decs TODO
 * @date 2025/4/14
 */
public class Practice01 {
    public static void main(String[] args) {
        boolean flag = true;
        String []date={"01.01", "01.02", "01.03",
                "05.01", "05.02", "05.03",
                "10.01", "10.02", "10.03", "10.04", "10.05", "10.06", "10.07"};
        Scanner scanner = new Scanner(System.in);
        System.out.println("请输入日期:(输入格式为MM.NN): ");
        String date1 = scanner.next();
        System.out.println("请输入票价：");
        double price = scanner.nextDouble();
        for (int i = 0; i < date.length; i++) {
            if (date1.equals(date[i])) {
                System.out.println("票价：" + price);
                flag = false;
                break;
            }
        }
        if (flag){
            System.out.println("票价：" + price * 0.8);
        }
    }

}
